package com.study.mvc.action;

import java.util.Map;

import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;

import com.study.mvc.action.base.Action;
import com.study.mvc.bean.LoginForm;
import com.study.mvc.bean.base.ActionForm;

public class LoginAction implements Action {

	public LoginAction() { 
	}

	@Override
	public String excute(HttpServletRequest request,HttpServletResponse response,ActionForm form,Map<String,String> forwordMap) {
		LoginForm loginForm=(LoginForm)form;
		String rstStr="";
		if(loginForm.getPassword().equals("")){
			
			rstStr="shibai";
		}else{
			rstStr="chenggong";
		}
		
		return forwordMap.get(rstStr);
	}

}
